<?php $this->load->view($config['site_template'].'/head');?>
<style type="text/css">
    .table>tbody>tr>td{
        border:2px solid #e7eaec;
    }
</style>

    <body class="gray-bg">

<!--    <div class="row  border-bottom white-bg dashboard-header">-->
<!--        <div class="col-sm-12">-->
<!--            <p>贵州智慧巡检破碎环节 数据推移图-->
<!--            </p>-->
<!---->
<!--        </div>-->
<!---->
<!--    </div>-->
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="row">
            <?php foreach ($productLine as $value):?>
                <div class="col-sm-6">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>气流磨粉碎过程操作记录表(<?=$value['lineName']?>)</h5>
                            <div class="ibox-tools">
                            </div>
                        </div>
                        <div class="ibox-content">
                            <div class="echarts" id="echarts_line_qlmfsgcczjlb_<?=$value['lineId']?>"></div>
                        </div>
                    </div>
                </div>
            <?php endforeach;?>
    </div>
    <script src="<?=$config['site_templateurl'];?>/js/Echarts/echarts.min.js?v=2.1.4"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            <?php foreach ($productLine as $val):?>
                //
                var showName_qlmfsgcczjlb_<?=$val["lineId"]?> = [], showData_qlmfsgcczjlb_<?=$val["lineId"]?>_WLJPL = [], showData_qlmfsgcczjlb_<?=$val["lineId"]?>_FJJPL = [], showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YFJPL = [], showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YMQY = [], showData_qlmfsgcczjlb_<?=$val["lineId"]?>_CCBPL = [];
                <?php foreach($qlmfsgcczjlb as $value):?>
                <?php if($value['productLine'] === $val['lineId']):?>
                    showName_qlmfsgcczjlb_<?=$val["lineId"]?>.push('<?=$value["year"]."-".$value["month"]."-".$value["day"]." ".$value["hour"]."H"?>');
                    showData_qlmfsgcczjlb_<?=$val["lineId"]?>_WLJPL.push("<?=$value['feederFrequency']?>");
                    showData_qlmfsgcczjlb_<?=$val["lineId"]?>_FJJPL.push("<?=$value['classifierFrequency']?>");
                    showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YFJPL.push("<?=$value['inducedDraftFrequency']?>");
                    showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YMQY.push("<?=$value['grindingAirPressure']?>");
                    showData_qlmfsgcczjlb_<?=$val["lineId"]?>_CCBPL.push("<?=$value['ultrasonicFrequency']?>");
                <?php endif;?>
                <?php endforeach;?>
                // 基于准备好的dom，初始化echarts实例
                var myChart_qlmfsgcczjlb_<?=$val["lineId"]?> = echarts.init(document.getElementById('echarts_line_qlmfsgcczjlb_<?=$val["lineId"]?>'));
                // 指定图表的配置项和数据
                var option_qlmfsgcczjlb_<?=$val["lineId"]?> = {
                    title: {
                        text: ''
                    },
                    tooltip: {
                        trigger: 'axis'
                    },
                    legend: {
                        data: ['喂料机频率设定(Hz)','分级机频率设定(Hz)','引风机频率设定(Hz)','研磨气压(Mpa)','超声波频率(Hz)']
                    },
                    toolbox: {
                        feature: {
                            saveAsImage: {}
                        }
                    },
                    xAxis: {
                        data: showName_qlmfsgcczjlb_<?=$val["lineId"]?>
                    },
                    yAxis: {},
                    series: [
                        {
                            name: '喂料机频率设定(Hz)',
                            type: 'line',
                            // data: [5, 20, 36, 10, 10, 20, 2],
                            data: showData_qlmfsgcczjlb_<?=$val["lineId"]?>_WLJPL,
                            smooth: true
                        },
                        {
                            name: '分级机频率设定(Hz)',
                            type: 'line',
                            // data: [120, 132, 101, 134, 90, 230, 210],
                            data: showData_qlmfsgcczjlb_<?=$val["lineId"]?>_FJJPL,
                            smooth: true
                        },
                        {
                            name: '引风机频率设定(Hz)',
                            type: 'line',
                            // data: [220, 182, 191, 234, 290, 330, 310],
                            data: showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YFJPL,
                            smooth: true
                        },
                        {
                            name: '研磨气压(Mpa)',
                            type: 'line',
                            // data: [220, 182, 191, 234, 290, 330, 310],
                            data: showData_qlmfsgcczjlb_<?=$val["lineId"]?>_YMQY,
                            smooth: true
                        },
                        {
                            name: '超声波频率(Hz)',
                            type: 'line',
                            // data: [220, 182, 191, 234, 290, 330, 310],
                            data: showData_qlmfsgcczjlb_<?=$val["lineId"]?>_CCBPL,
                            smooth: true
                        },
                    ]
                };

                // 使用刚指定的配置项和数据显示图表。
                myChart_qlmfsgcczjlb_<?=$val["lineId"]?>.setOption(option_qlmfsgcczjlb_<?=$val["lineId"]?>);
            <?php endforeach;?>

        })

    </script>
    </body>

<?php $this->load->view($config['site_template'].'/foot');?>